
#ifndef __MOF_FLASH_CORE_H_
#define __MOF_FLASH_CORE_H_

#include <mof_stdint.h>

#include "py32f002b_ll_flash.h"

#define FLASH_USER_START_ADDR     0x08005000
#define FLASH_USER_PAGE0     FLASH_USER_START_ADDR
#define FLASH_USER_PAGE1     (FLASH_USER_PAGE0+FLASH_PAGE_SIZE)
#define FLASH_USER_PAGE2     (FLASH_USER_PAGE1+FLASH_PAGE_SIZE)
#define FLASH_USER_PAGE3     (FLASH_USER_PAGE2+FLASH_PAGE_SIZE)


void mof_flash_init(void);

void mof_flash_read(uint32_t addr_start,uint32_t *src,uint32_t u32_len);

void mof_flash_write(uint32_t addr_start,uint32_t *src,uint32_t u32_len);
	

#endif




